package jzqb.dao.impl;

import cnki.tpi.kbatis.sqlsession.SqlSession;
import cnki.tpi.kbatis.utils.DataSourceUtil;
import jzqb.dao.ILCDao;
import jzqb.po.LCPo;
import org.springframework.stereotype.Repository;

/**
 * Description:
 *
 * @author BaiGe
 * @date: 2021/6/23 15:44
 * @Version 1.0
 */
@Repository
public class LCDaoImpl implements ILCDao {
    @Override
    public Boolean addLc(LCPo lcPo) {
        SqlSession sqlSession = DataSourceUtil.getSqlSession();
        String statementId = "jzqb.dao.ILCDao.addLc";
        return sqlSession.executeInsert(statementId, lcPo);
    }
    @Override
    public Boolean updateLc(LCPo lcPo) {
        SqlSession sqlSession = DataSourceUtil.getSqlSession();
        String statementId = "jzqb.dao.ILCDao.updateLc";
        return   sqlSession.executeUpdate(statementId, lcPo);
    }

    @Override
    public Boolean delThreeLc(Integer qbfwId) {
        SqlSession sqlSession = DataSourceUtil.getSqlSession();
        String statementId = "jzqb.dao.ILCDao.delThreeLc";
        return sqlSession.executeDelete(statementId, qbfwId);
    }
}
